<?php

namespace common\models;

use Yii;

/**
 * This is the model class for table "t_google".
 *
 * @property int $id
 * @property string $title
 * @property string $longitude 经度
 * @property string $latitude 纬度
 * @property int|null $type 分类
 * @property string|null $create_time 创建时间
 */
class Google extends \yii\db\ActiveRecord
{
    /**
     * {@inheritdoc}
     */
    public static function tableName()
    {
        return 't_google';
    }

    /**
     * {@inheritdoc}
     */
    public function rules()
    {
        return [
            [['title', 'latitude'], 'required'],
            [['type'], 'integer'],
            [['create_time'], 'safe'],
            [['title'], 'string', 'max' => 100],
            [['longitude', 'latitude'], 'string', 'max' => 50],
        ];
    }

    /**
     * {@inheritdoc}
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'title' => 'Title',
            'longitude' => '经度',
            'latitude' => '纬度',
            'type' => '分类',
            'create_time' => '创建时间',
        ];
    }
}
